#pragma once
#include "interfaces/InputOutputPlugin.h"
#include "SkeletonModel.h"

/// Make this function valid only in this file
namespace{
    bool isaSkeleton(Model* model){
        return qobject_cast<SkeletonModel*>(model);
    }
    SkeletonModel* safeCast(Model* model){
        SkeletonModel* _model = qobject_cast<SkeletonModel*>(model);
        if(!_model) throw StarlabException("Model is not a SurfaceMeshModel");
        return _model;
    }
}

class SkeletonInputOutputPlugin : public InputOutputPlugin{
private: 
    bool isApplicable(Model* model){ return isaSkeleton(model); }
};
